home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / comm / tlx_sq21.zip / PASSWORD.SLT < prev    next >
Text File  |  1992-01-13  |  1KB  |  38 lines

  1. //-----------------------------------------------------------
  2. // PASSWORD.SL? Send password.
  3. //
  4. // Please look at the comments through the whole file, and modify to
  5. // suit your needs, BEFORE you use it. Then recompile with CS PASSWORD.
  6. //-----------------------------------------------------------
  7.  
  8. // If you have suggestions for improving this script, please suggest
  9. // improvements to me via old-fashioned snail-mail to:
  10.  
  11. // Author:  Inge Vabekk
  12. //          Hamangskogen 108
  13. //          N-1300 SANDVIKA
  14. //          NORWAY
  15. //          tel. (472) 546 396
  16.  
  17. str global[]="GLOBAL"
  18.    ,passw []="PASSW"
  19.    ;
  20.  
  21. //-----------------------------------------------------------
  22. // Script starts here.
  23. //-----------------------------------------------------------
  24.  
  25. main()
  26. {
  27. int i;
  28. str line[20];
  29.  
  30.   call (global,"R",passw,line);          // Get password.
  31.   i = strlen (line)-1;
  32.   if (subchr (line,i)<=' ')              // Delete any trailing CR.
  33.   setchr (line,i,0);
  34.   cputs (line);                          // Send it.
  35.   cputs ("^M");
  36. }
  37.  
  38.